# -*- mode: snippet -*-
# name: set default arguments
# key: arg
# --
% argument checking 
if nargin < 1
    error('Not enough arguments')
elseif nargin > 3
    error('Too many arguments')
end

switch nargin
  case 1
    argument2 = 0;
    argument3 = 0;
  case 2
    argument3 = 0;
end
